Arithmetic overflows now return float rather than wrapping around.
authorPaul Eggert <eggert@cs.ucla.edu>
Tue, 3 May 2011 07:51:38 +0000 (00:51 -0700)
committerPaul Eggert <eggert@cs.ucla.edu>
Tue, 3 May 2011 07:51:38 +0000 (00:51 -0700)
commit73235992e0671a38e9445fdd4d3eee547807f0e3
tree4bc58c842a0b615559e4abfee91140ee4d2a2d2f
parent9cc3710eab9ad002ab4088df094e08363adfd395
Arithmetic overflows now return float rather than wrapping around.

* data.c: Include <intprops.h>.
(arith_driver): Use floating point if the accumulator would otherwise
go out of EMACS_INT range.
(arith_driver, Fadd1, Fsub1): Use floating point if the result is
out of Emacs fixnum range.
* bytecode.c (exec_byte_code): Likewise, for Bsub1, Badd1, Bnegate.
src/ChangeLog
src/bytecode.c
src/data.c